package com.zjcode.cdcer.service;

import com.chinatechstar.component.commons.result.ListResult;
import com.chinatechstar.component.commons.supports.PageData;
import com.zjcode.cdcer.model.basic.JsonObj;
import com.zjcode.cdcer.service.fallback.CerPersonInfoServiceFallback;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;

/**
 * @createTime: 2023-10-07
 * @creater: yong
 */
@FeignClient(value = "zjcode-chronic-disease-cancer-server", fallback = CerPersonInfoServiceFallback.class)
public interface CerPersonInfoService {
    @GetMapping("/cdcerserver/v1/cerpersoninfo/nationlist")
    JsonObj nationlist();
    @GetMapping("/cdcerserver/v1/cerpersoninfo/listPagePerson")
    JsonObj listPagePerson(PageData pageData);
    @PostMapping(value = "/cdcerserver/v1/cerpersoninfo/uploadFile4CerDataInit")
    JsonObj uploadFile4CerDataInit(@RequestParam("file") MultipartFile file, HttpServletResponse response);

    @PostMapping("/cdcerserver/v1/cerpersoninfo/editPersonInfo")
    public JsonObj editPersonInfo(@RequestBody PageData pageData);
    @PostMapping("/cdcerserver/v1/cerpersoninfo/queryPersonInfoByNameOrIdCard")
    public JsonObj queryPersonInfoByNameOrIdCard(@RequestBody PageData pageData);

    @PostMapping("/cdcerserver/v1/cerpersoninfo/getCity")
    public JsonObj getCity(@RequestBody PageData pageData);

    @PostMapping("/cdcerserver/v1/cerpersoninfo/queryAllExportData")
    JsonObj queryAllExportData(@RequestBody PageData pageData);

    @GetMapping("/cdcerserver/v1/cerpersoninfo/delPersonInfo")
    JsonObj delPersonInfo(@RequestParam String id);
}
